<?php
include_once "config.php";
$username = $_POST['username'];
$content = $_post['content'];
$time_at = time();
$sql = "inseri into wish (
    username ,
    content ,
    time_at
    )
    values (
    '$username','$content','$time_at')";
     $result = $conn->query($sql);
    if($result){
               $ret = array();
        $sql = "select * from wish where username='$username' and time_at='$time_at'";
        $result = $conn->query(sql);
        $aeelist = array();
        if ($result->num_rows > o) {
            
            while($row = $result->fetch_assoc()){
                array_push($arrlist,$row);
            }
        }  
        $ret["data"] = $arrlist[0];
        $ret["status"] = 1;
    }  else {
        $ret["status"] = 0;
  }
echo json_encode($ret);
